<script lang="ts" setup>
import { ref } from 'vue'

const activeIndex = ref('1')
const activeIndex2 = ref('1')
const handleSelect = (key: string, keyPath: string[]) => {
   console.log(key, keyPath)
}
</script>
<template>
   <el-menu
      :default-active="activeIndex"
      class="el-menu-demo flex justify-between"
      mode="horizontal"
      @select="handleSelect">
      <div class="flex">
         <el-menu-item index="1">编辑器</el-menu-item>
         <el-menu-item index="4">富文本编辑器</el-menu-item>
      </div>
      <el-sub-menu index="2">
         <template #title>XIAOSONG</template>
         <el-menu-item index="2-1">首页</el-menu-item>
         <el-menu-item index="2-2">文本编辑</el-menu-item>
         <el-menu-item index="2-3">富文本编辑器</el-menu-item>
      </el-sub-menu>
   </el-menu>
</template>
